<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>
  <script>
    function fn1() {

    }
    fn1.prototype.msg = 'hello'
    let obj1 = new fn1()
    let obj2 = new fn1()
    obj1.__proto__.msg = 'yyds'
    console.log(obj1.msg);  //nonono
    console.log(obj2.msg);  //yyds
  //栈                        堆
  // fn1.prototype:地址0     {msg:'yyds'}
  //obj1 地址1               {__proto__:地址0}
  //obj2 地址2               {__proto__:地址0}
  </script>
</body>

</html>